home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1999 March / EnigmA AMIGA RUN 35 (1999)(G.R. Edizioni)(IT)[!][issue 1999-03].iso / earcd / devel / vbcc-ppc-src / ar / ar.h < prev    next >
C/C++ Source or Header  |  1999-01-01  |  3KB  |  82 lines

  1. /* $VER: ar ar.h V0.1 (31.01.98)
  2.  *
  3.  * This file is part of ar, a portable archive maintanance
  4.  * utility for normal and BSD-style archives.
  5.  * Copyright (c) 1999  Frank Wille
  6.  *
  7.  * ar is freeware and part of the portable and retargetable ANSI C
  8.  * compiler vbcc, copyright (c) 1995-99 by Volker Barthelmann.
  9.  * ar may be freely redistributed as long as no modifications are
  10.  * made and nothing is charged for it. Non-commercial usage is allowed
  11.  * without any restrictions.
  12.  * EVERY PRODUCT OR PROGRAM DERIVED DIRECTLY FROM MY SOURCE MAY NOT BE
  13.  * SOLD COMMERCIALLY WITHOUT PERMISSION FROM THE AUTHOR.
  14.  *
  15.  *
  16.  * v0.1  (31.01.99) phx
  17.  *       First working version, which only supports 'q' (quick append)
  18.  *       and 't' (table of contents), reads and writes normals and
  19.  *       BSD-style archives. Symbol table will not be created!
  20.  * v0.0  (29.01.99) phx
  21.  *       File created.
  22.  */
  23.  
  24. /* version/revision */
  25. #define PNAME "ar"
  26. #define VERSION 0
  27. #define REVISION 1
  28. #define PLEVEL 0
  29.  
  30.  
  31. /* integer types */
  32. #if defined (TYPES32BIT)
  33. typedef signed char int8;
  34. typedef unsigned char uint8;
  35. typedef signed short int int16;
  36. typedef unsigned short int uint16;
  37. typedef signed long int int32;
  38. typedef unsigned long int uint32;
  39. typedef signed char bool;
  40. #elif defined (TYPES64BIT)
  41. typedef signed char int8;
  42. typedef unsigned char uint8;
  43. typedef signed short int16;
  44. typedef unsigned short uint16;
  45. typedef signed int int32;
  46. typedef unsigned int uint32;
  47. typedef int bool;
  48. #else
  49. #error Unsupported architecture! Define either TYPES32BIT or TYPES64BIT.
  50. #endif
  51.  
  52.  
  53. #ifndef TRUE
  54. #define TRUE 1
  55. #endif
  56. #ifndef FALSE
  57. #define FALSE 0
  58. #endif
  59. #ifndef NULL
  60. #define NULL 0
  61. #endif
  62.  
  63.  
  64. /* modifier flags */
  65. #define AR_BEFORE       0x0001  /* insert before position */
  66. #define AR_AFTER        0x0002  /* insert after position */
  67. #define AR_UPDATE       0x0004  /* replace/extract only when newer */
  68. #define AR_PRESERVE     0x0008  /* preserve permissions and time on extract */
  69. #define AR_CREATIGN     0x0010  /* no message when creating a new archive */
  70. #define AR_TRUNC        0x0100  /* truncate file names > 15 chars */
  71. #define AR_BSD          0x0200  /* write BSD format symbol names */
  72. #define AR_VERBOSE      0x8000  /* verbose output  */
  73. #define AR_POS          0x0003  /* position mask */
  74.  
  75. struct Args {
  76.   char *arname;                 /* archive name */
  77.   char **files;                 /* ptr to filecnt file names (may be NULL) */
  78.   char *position;               /* position file name (may be NULL) */
  79.   uint32 modifier;              /* modifier flags */
  80.   int filecnt;                  /* number of files */
  81. };
  82.